package com.zhongxi.guoyuan.entity.user;

import org.json.JSONObject;

/**
 * Created by Administrator on 2016/11/17.
 */

public class UserData {

    private String id;
    private String username;
    private String mphone;
    private String avatar;
    private String isshareholders;   //是否股东
    private String isbeneficiary;   //是否消费收益人
    private String ismerchants;    // 是否商家用户
    private String appopenid;  // 微信标识id
    private String deleted;
    private String mpopenid;
    private String pwd;
    private String registrationid;

    private String isprivilege;
    private String shopname;
    private String ctime;
    private int ispartner;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getMphone() {
        return mphone;
    }

    public void setMphone(String mphone) {
        this.mphone = mphone;
    }

    public String getAvatar() {
        return avatar;
    }

    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }

    public String getShopname() {
        return shopname;
    }

    public void setShopname(String shopname) {
        this.shopname = shopname;
    }

    public String getIsshareholders() {
        return isshareholders;
    }

    public void setIsshareholders(String isshareholders) {
        this.isshareholders = isshareholders;
    }

    public String getIsprivilege() {
        return isprivilege;
    }

    public void setIsprivilege(String isprivilege) {
        this.isprivilege = isprivilege;
    }

    public String getIsbeneficiary() {
        return isbeneficiary;
    }

    public void setIsbeneficiary(String isbeneficiary) {
        this.isbeneficiary = isbeneficiary;
    }

    public String getIsmerchants() {
        return ismerchants;
    }

    public void setIsmerchants(String ismerchants) {
        this.ismerchants = ismerchants;
    }

    public String getCtime() {
        return ctime;
    }

    public void setCtime(String ctime) {
        this.ctime = ctime;
    }

    public int getIspartner() {
        return ispartner;
    }

    public void setIspartner(int ispartner) {
        this.ispartner = ispartner;
    }

    public String getAppopenid() {
        return appopenid;
    }

    public void setAppopenid(String appopenid) {
        this.appopenid = appopenid;
    }

    public String getDeleted() {
        return deleted;
    }

    public void setDeleted(String deleted) {
        this.deleted = deleted;
    }

    public String getMpopenid() {
        return mpopenid;
    }

    public void setMpopenid(String mpopenid) {
        this.mpopenid = mpopenid;
    }

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public String getRegistrationid() {
        return registrationid;
    }

    public void setRegistrationid(String registrationid) {
        this.registrationid = registrationid;
    }

    public static UserData parseMatch(JSONObject jsonObject) {
        UserData userData = new UserData();
        try {
            userData.setMphone(jsonObject.getString("mphone"));
            userData.setUsername(jsonObject.getString("username"));
        } catch (Exception e) {
            e.printStackTrace();
        }
        return userData;
    }
}
